package com.zjb.zjbHome.model.model;

import java.util.List;

import com.zjb.zjbHome.model.base.BaseUrl;

public class Url extends BaseUrl<Url> {

	private static final long serialVersionUID = -1464362619619500540L;
	
	public static final Url dao = new Url();
	
	public List<Url> search(){
		return this.find("select * from url");
	}

	public int add(String urlName, String urlPath, String introduce) {
		Url urls = new Url();
		urls.setUrlName(urlName);
		urls.setUrl(urlPath);
		urls.setIntroduce(introduce);
		urls.save();
		
		return urls.getId();
	}
}
